package Common;

// 三段码中的操作指令
// 算术运算、赋值、跳转、函数调用等
public enum TacOp {
    ADD("add"),
    SUB("sub"),
    MUL("mul"),
    DIV("div"),
    ASSIGN("assign"),
    CALL("call"),
    PARA("para"),
    RET("ret"),
    ENDCALL("encode"),
    FUN_RET("function_return"),
    FUN_PARA("function_param"),
    GOTO("goto"),
    IFGT("ja"),
    IFGE("jae"),
    IFLT("jb"),
    IFLE("jbe"),
    IFEQ("je"),
    IFNEQ("jne"),
    LABEL("label"),
    CREATLIST("create_list"),
    ;

    public String name;
    TacOp(String s) {
        this.name = s;
    }
    public String commonop2String(){
        return this.name;
    }
}
